#!/bin/bash
# 统计代码行数
gcc codeline.c -o codeline -Wall

FPATH=./C_version
FTYPE=("*.h" "*.c" "*.build" "*.xml" "*.ui" "Makefile")

for _t in "${FTYPE[@]}"
do
	echo "find $FPATH -name '${_t}'"
	find $FPATH -name "${_t}" -exec wc -l {} \; | awk '{print $1}' >> line.txt
done

./codeline line.txt
rm line.txt
rm codeline
